1. Field of the Invention
This invention relates to computer systems and, more particularly, to directory name lookup caches within a clustered file system.
2. Description of the Related Art
File systems organize and manage information stored in a computer system. Typically, information is stored in the form of files. File systems may support the organization of user data by providing and tracking organizational structures such as folders or directories. The file system may interpret and access information physically stored in a variety of storage media, abstracting complexities associated with the tasks of locating, retrieving, and writing data to the storage media.
Files are typically located by specifying a path to that file. The path may indicate which directories or folders include that particular file. A typical path is a sequence of directory or folder names, starting at the file system's root directory, and ending with the name of the file or directory being identified.
In some operating environments such as UNIX, information about each file in the file system is kept in a metadata structure called an inode. The inode contains metadata, which includes a pointer to the physical blocks containing the data in the file and information indicating the type of file, the permission bits, the owner and group, the file size, and the file modification date and time. Terms such as file nodes, file table entries, and snodes are also used to identify similar metadata structures. For example, the term “master file table entry” is used in some Windows™ based file systems.
File systems often include a special cache, typically called a DNLC (Directory Name Lookup Cache), to store pathname to inode translations. Without a DNLC, all pathname to inode translations involve scanning each directory in the path to get the inode identifiers for the targeted file and each of that file's parent directories. Since the directories are located on disk, these accesses can take a significant amount of time. A DNLC caches inode information for recently accessed files so that at least some of these disk accesses can be avoided.
As with other caches, problems with cache coherency can arise when multiple components in a system can act in ways that affect the validity of information in other components' DNLCs. For example, in a clustered system that includes multiple computing nodes, each node may be able to manipulate files in a particular file system. If one node has cached information for a particular file in its DNLC and another node renders that information invalid (e.g., by removing the file), the node with the cached information needs to be notified that its information for that particular file is no longer reliable. However, providing such notification may consume an undesirable amount of system resources.